

class Gta <T>{
    private T[] array = (T[])new Object[10];
    public void setArray(String input, int pos){
        this.array[pos] = (T)input;
    }
    public T getArray(int pos){
        return array[pos];
    }
}
public class Test{
    public static void main(String[] args){
        Gta<String> gta = new Gta<String>();
        gta.setArray("hello China!",0);
        System.out.println(gta.getArray(0));
    }
}